Skip to main content
This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal

Notes/Domino 6 and 7 Forum

Notes/Domino 6 and 7 Forum


  

PreviousPrevious NextNext

Smartcard-enabling an ID file through the C API
~Umberto Nongeroson 14.Jan.04 06:08 PM a Web browser
Notes Client All Releases All Platforms


The path to the DLL is stored in the PKCS11_Library notes.ini variable, and after setting that you can programatically smartcard-enable an ID file by using the SECManipulateSC API function in a manner similar to the pseudocode below. The full functionality of SECManipulateSC is documented along with the rest of the C API.


SCMCTX Context = NULLSCMCTX;
error = SECManipulateSC (SC_manip_GetVersion,
                             NULLSCMCTX,
NULL,
&Version,
NULL);

/* Initialize the PKCS#11 context.
 */
error = SECManipulateSC (SC_manip_InitializeContext,
&Context,
NULL, NULL, NULL);

/* Set up the ID file
 */
error = SECManipulateSC (SC_manip_EnterIDFile,
&Context,
NULL,
&dwIDLen,
IDPath);

/* Unlock the smartcard
 */
error = SECManipulateSC (SC_manip_EnterPIN,
&Context,
NULL,
&dwPINLen,
PIN);

/* Note -- SC_manip_EnterPIN will use an external authentication path if it exists. If the token doesn't support a protected authentcation path, SC_manip_EnterPIN will use the supplied PIN if one exists or generate a prompt if a NULL or zero-length PIN was used. */

/* Smartcard-enable the ID file
 */
error = SECManipulateSC (SC_manip_SCEnableID,
&Context,
NULL,
&dwNotesIDPasswordLen,
pNotesIDPassword);

/* Note -- SC_manip_SCEnableID will prompt for the password to the ID file if it is not
given as a parameter */

/* Clean up
*/
SECManipulateSC (SC_manip_TerminateContext,
  &Context,
                 NULL, NULL, NULL);




SmardCard Delete Key Problem / Decr... (~August Zenhipi... 8.Jan.04)
. . RE: SmardCard Delete Key Problem / ... (~Tanita Desweve... 9.Jan.04)
. . . . RE: SmardCard Delete Key Problem / ... (~August Zenhipi... 12.Jan.04)
. . . . . . RE: SmardCard Delete Key Problem / ... (~Tanita Desweve... 13.Jan.04)
. . . . . . . . RE: SmardCard Delete Key Problem / ... (~August Zenhipi... 14.Jan.04)
. . . . . . . . . . Smartcard-enabling an ID file throu... (~Tanita Desweve... 14.Jan.04)


Document Options






  Document options
Print this pagePrint this page

Search this forum

Forum views and search


  Forum views and search
Date (threaded)
Date (flat)
With excerpt
Category
Platform
Release
Advanced search

Member Tools


RSS Feeds

 RSS feedsRSS
All forum posts RSS
All main topics RSS